home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MACD 5
/
MACD 5.bin
/
polski_aminet
/
piotr_pawlow
/
mapatch28->29
/
patch.install
< prev
next >
Wrap
Text File
|
1997-05-14
|
2KB
|
74 lines
; MiniArcanoid Installer script
(procedure P_PATCHFILE #old #new #patch
(
(set #err
(run ("patch \"%s\" \"%s\" \"%s\" QUIET" #old #new #patch))
)
(if (<> #err 0)
(if (= #err 9)
(
(working ("File \"%s\" is already patched" #old))
(run ("wait 2"))
)
(abort
(select (- #err 10)
"Not enough memory"
"Read error"
"Wrong version of patch command\nor something strange has happened"
"*** BREAK ***"
("Couldn't write file \"%s\"" #new)
("Wrong \"%s\" file format" #patch)
("Wrong \"%s\" file size.\nProbably it's incorrect version." #old)
("Wrong \"%s\" file checksum.\nProbably the file has been altered." #old)
)
)
)
)
)
)
(welcome)
(set #destdir
(askdir
(prompt "Select where are your MiniArcanoid files\n(Enter MiniArcanoid directory)")
(help @askdir-help)
(default @default-dest)
)
)
(set #destexe (tackon #destdir "MiniArcanoid"))
(set #destguide (tackon #destdir "MiniArcanoid.guide"))
(set #destinstall (tackon #destdir "MiniArcanoid.install"))
(working "Patching MiniArcanoid executable...")
(if
(not (exists #destexe))
(abort "MiniArcanoid executable not found!")
)
(P_PATCHFILE #destexe #destexe "MiniArcanoid.pch")
(copyfiles
(prompt "Copying new samples")
(source "")
(dest #destdir)
(help @copyfiles-help)
(pattern "#?.snd")
(infos)
)
(if (exists #destguide)
(
(working "Patching MiniArcanoid documentation...")
(P_PATCHFILE #destguide #destguide "MiniArcanoid.guide.pch")
)
)
(if (exists #destinstall)
(
(working "Patching installer script...")
(P_PATCHFILE #destinstall #destinstall "MiniArcanoid.install.pch")
)
)
(exit)